package com.hq.useBatis.mapper;

import com.hq.useBatis.entity.Student;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @Auther: fsxa
 * @Date: 2018/12/17 15:55
 * @Description:
 */
@Mapper
public interface StudentMapper {

    @Select("select * from students where id=#{id}")
    public Student findById(int id);

    @Select("select * from students")
    public List<Student> findAll();

}
